home *** CD-ROM | disk | FTP | other *** search
- package koala.dynamicjava.tree;
-
- import java.util.LinkedList;
- import java.util.List;
- import koala.dynamicjava.tree.visitor.Visitor;
-
- public class ForStatement extends Statement implements ContinueTarget {
- public static final String INITIALIZATION = "initialization";
- public static final String CONDITION = "condition";
- public static final String UPDATE = "update";
- public static final String BODY = "body";
- private List initialization;
- private Expression condition;
- private List update;
- private Node body;
- private List labels;
-
- public List getInitialization() {
- return this.initialization;
- }
-
- public void setInitialization(List var1) {
- ((Node)this).firePropertyChange("initialization", this.initialization, this.initialization = var1);
- }
-
- public Expression getCondition() {
- return this.condition;
- }
-
- public void setCondition(Expression var1) {
- ((Node)this).firePropertyChange("condition", this.condition, this.condition = var1);
- }
-
- public List getUpdate() {
- return this.update;
- }
-
- public void setUpdate(List var1) {
- ((Node)this).firePropertyChange("update", this.update, this.update = var1);
- }
-
- public Node getBody() {
- return this.body;
- }
-
- public void setBody(Node var1) {
- if (var1 == null) {
- throw new IllegalArgumentException("node == null");
- } else {
- ((Node)this).firePropertyChange("body", this.body, this.body = var1);
- }
- }
-
- public void addLabel(String var1) {
- if (var1 == null) {
- throw new IllegalArgumentException("label == null");
- } else {
- this.labels.add(var1);
- }
- }
-
- public boolean hasLabel(String var1) {
- return this.labels.contains(var1);
- }
-
- public Object acceptVisitor(Visitor var1) {
- return var1.visit(this);
- }
-
- public ForStatement(List var1, Expression var2, List var3, Node var4) {
- this(var1, var2, var3, var4, (String)null, 0, 0, 0, 0);
- }
-
- public ForStatement(List var1, Expression var2, List var3, Node var4, String var5, int var6, int var7, int var8, int var9) {
- super(var5, var6, var7, var8, var9);
- if (var4 == null) {
- throw new IllegalArgumentException("body == null");
- } else {
- this.initialization = var1;
- this.condition = var2;
- this.update = var3;
- this.body = var4;
- this.labels = new LinkedList();
- }
- }
- }
-